<?php
require_once $_site->get_viewpath("mobile/common/authcheck");
require_once $_site->get_viewpath("mobile/common/header");

$id=request('id',false,true);
if(!$id)return false;

//查询管理员信息
$admin_objet=new manager();
$pid=$admin_objet->admin_project_id();

$gas_object=new gas();
$info=$gas_object->getGas($id);

//绑定信息
if(empty($info['dophone'])){
   $binfo=$admin_objet->bind_info($info['did'],'phone');
}else{
   $binfo['phone']=$info['dophone'];
}
//项目名称
$pinfo=$admin_objet->project_info($info['pid'],'title');
//项目经理账号
$admininfo=$admin_objet->projecter_info($info['xid'],'name');


$truckType=array('a'=>'A 型','b'=>'B 型','c'=>'C 型');
$dustType=array('1'=>'Ⅰ类','2'=>'Ⅱ类','3'=>'Ⅲ 类');
$onloadType=array(1=>"空车",2=>"重车");
$stateType=array(1=>"有效",0=>"无效");
$typeAry=array(1=>'挖机装车 ',2=>'挖机计时',3=>'渣车登记');
?>	
</head>

	<body>
		<div class="headertwo clearfloat" id="header">
			<a href="javascript:history.go(-1)" class="fl box-s"><i class="iconfont icon-arrow-l fl"></i></a>
			<p class="fl">记录详情</p>		
			<a href="/mobile/center" class="fr"><i class="iconfont icon-gerenzhongxin fl"></i></a>	
		</div>
		
		<!--分享内容-->		
		<div class="clearfloat" id="main">		
			<div class="service clearfloat">
				<div class="slider one-time">
					<div>
						<img src="<?php echo $info['img_start'];?>"/>
					</div>
				</div>												
			</div>		
			
			<div class="service-top clearfloat box-s" style="margin-top:0px;">
				<div class="left fl clearfloat box-s" style="width: 100%;border-right:0px;">
					<p class="tit titwo">加油前  | <span class="fu-tit" style="color:red;"><?php echo $info['num_start']; ?></span> |  <span class="fu-tit"><?php echo date("Y-m-d H:i:s",$info['time_start'])?></span></p>					
				</div>
			</div>										
			
			<div class="service clearfloat">
				<div class="slider one-time">
					<div>
						<img src="<?php echo $info['img_end'];?>"/>
					</div>																
				</div>
			</div>				
			
			<div class="service-top clearfloat box-s" style="margin-top:0px;">
				<div class="left fl clearfloat box-s" style="width: 100%;border-right:0px;">
					<p class="tit titwo">加油后  | <span class="fu-tit" style="color:red;"><?php echo $info['num_end']; ?></span> |  <span class="fu-tit"><?php echo date("Y-m-d H:i:s",$info['time_end'])?></span></p>					
				</div>
			</div>				
			
						
			<div class="service-ctent clearfloat">
				<div class="recom-tit clearfloat box-s">
		    		<p>记录信息</p>
		    	</div>
		    	<div class="service-list clearfloat box-s">
		    		<ul>
		    		    <?php 
		    		       if(1==$info['type']){
		    		    ?>
		    			<li>类型：加油记录</li>
		    			<li>设备号：<?php echo $info['no']?></li>
		    			<li>用时：<?php echo timeparsesecond($info['time_all']);?></li>
		    			<li>加油量：<?php echo $info['num_all']?></li>
		    			<li>员工编号：<?php echo $info['gaser']?></li>
		    			<li>油罐编号：<?php echo $info['gascan']?></li>
		    			<li>加油车号：<?php echo $info['carno']?></li>
		    			<li>产权人：<?php echo $info['downer']?></li>		    					    		
		    			<li>项目名称：<?php echo $pinfo['title'];?></li>
		    			<li>项目经理：<?php echo $admininfo['name'];?></li>
		    			<?php 
		    			   }elseif(2==$info['type']){
		    			?>
		    			<li>类型：进油记录</li>
		    			<li>设备号：<?php echo $info['no']?></li>
		    			<li>用时：<?php echo timeparsesecond($info['time_all']);?></li>
		    			<li>加油量：<?php echo $info['num_all']?></li>
		    			<li>员工编号：<?php echo $info['gaser']?></li>
		    			<li>油罐编号：<?php echo $info['gascan']?></li>		    			
		    			<li>项目名称：<?php echo $pinfo['title'];?></li>
		    			<li>项目经理：<?php echo $admininfo['name'];?></li>		    					    			
		    			<?php 
		    			   }
		    			?>
		    		</ul>		    		
		    	</div>		    	
			</div>
	

		</div>
			
	</body>
	
</html>